Indentions

The "Comments" plug-in provides keyboard shortcuts for the Lpex editor for commenting and uncommenting source lines. It is also possible to toggle a source line from commented to uncommented and vice versa. The provided keyboard shortcuts are

Ctrl+TabIndent source line
Ctrl+Shift+TabUnindent source line

You can also select the required function from the context menu:

The supported source types are:

The amount of spaces for indenting/unindenting a source line is retrieved from option Automatic indent, Blanks (1-20): of the ILE RPG IBM i Parsers preference page for older IDEs.

For newer IDEs, such as RDi 9.5, that value is retrieved from option Number of spaces to indent by, Blanks (1-20): of the ILE RPG Formatter page.

When option Set free form C-Specification cursor position is enabled (same preference page), the position specified there is used as a tabulator when indenting/unindenting source lines.

Indenting A Source Line

Put the cursor on the source line that you want to indent and press the keyboard shortcut or select the requested option from the context menu.

Changing Multiple Source Lines

Select the source lines that you want to indent and press the keyboard shortcut or select the requested option from the context menu. For example you can select lines 123-124 like this:

The result looks like that:

It is not required to select the complete source lines. Just start somewhere in the first line to change and span the selection to the last line. Then select the requested action.